<template>
  <div>
    <ul>
      <li v-for="item in data">
        <router-link to="/detail">
          <img :src="item.src" alt="">
          <P>{{item.tit}}</P>
          <P>{{item.txt}}</P>
          <div class="foot">
            <p>
              <span>{{item.txt2}}</span>
              <span>{{item.pice}}</span>
            </p>
            <router-link to="/shopyes/1">
              <img :src="item.src2" alt="">
            </router-link>
          </div>
        </router-link>
      </li>
    </ul>
  </div>
</template>

<script>
    export default {
      name: "Moudel",
      data(){
        return {
          data:[
            {src:'/static/lyl/l5.png',tit:'新西兰佳沛黄金奇异果',txt:'果肉绵密、花蜜般的甘甜百吃不厌',txt2:'￥28.80  ',pice:'¥40.00',src2:'/static/lyl/dagou.png'},
            {src:'/static/lyl/l5.png',tit:'新西兰佳沛黄金奇异果',txt:'果肉绵密、花蜜般的甘甜百吃不厌',txt2:'￥28.80  ',pice:'¥40.00',src2:'/static/lyl/dagou.png'},
            {src:'/static/lyl/l5.png',tit:'新西兰佳沛黄金奇异果',txt:'果肉绵密、花蜜般的甘甜百吃不厌',txt2:'￥28.80  ',pice:'¥40.00',src2:'/static/lyl/dagou.png'},
            {src:'/static/lyl/l5.png',tit:'新西兰佳沛黄金奇异果',txt:'果肉绵密、花蜜般的甘甜百吃不厌',txt2:'￥28.80  ',pice:'¥40.00',src2:'/static/lyl/dagou.png'}
          ]
        }
      }
    }
</script>

<style scoped>
  ul{
    width: 1280px;
    margin:0 auto 20px;
    display: flex;
    justify-content: space-between;
  }
  ul li{
    width: 302px;
    border: 1px solid #ececec;
    text-align: center;
    padding-bottom: 25px;
  }
  ul li>a>img{
    width: 260px;
  }
  ul li a>p{
    text-align: left;
    padding-left: 20px;
  }
  ul li a>p:nth-child(2){
    font-size: 18px;
    line-height: 36px;
  }
  ul li a>p:nth-child(3){
    font-size: 12px;
    line-height: 36px;
    color: #666;
  }
  ul li .foot{
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
  }
  ul li .foot p span{
    font-size: 20px;
    line-height: 30px;
  }
  ul li .foot p span:nth-child(1){
    color: #ff5757;
  }
  ul li .foot p span:nth-child(2){
    font-size: 16px;
    text-decoration: line-through;
    color: #666;
  }
</style>
